<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" th:href="@{/lay/lib/layui-v2.5.5/css/layui.css}" media="all">
    <link rel="stylesheet" th:href="@{/lay/css/public.css}" media="all">
    <style>
        body {
            background-color: #ffffff;
        }

        ._input{
            border: 1px solid #d7cece;
            width: 280px;
        }

        ._textarea{
            width: 52vw;
            /*height: 60px;*/
            border: 1px solid #d7cece;
        }
         .layui-textarea{
             height: 60px;
        }
         .layui-form-select dl{
             max-height:200px
         }
    </style>
</head>
<body   >
<form class="layui-form" lay-filter="form" action="">
    <input id="id" name="id"  hidden th:value="${edit?info.id:0}">
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">日期</label>
            <div class="layui-input-inline _input">
                <input type="text" name="date" id="date" th:value="${#dates.format(edit?info.date:#dates.createNow(),'yyyy-MM-dd')}"
                       lay-verify="required|date" class="layui-input">
            </div>
        </div>

        <div class="layui-inline">
            <label class="layui-form-label">教室名称</label>
            <div class="layui-input-inline _input">
                <select name="classroomid"   lay-verify="required" lay-search="">
                    <option th:unless="${edit}" value="">直接选择或搜索选择</option>
                    <option th:each="item:${classroom}" th:checked="${edit?item.id==info.classroomid:false}" th:value="${item.id}" th:text="${item.classroomName}"></option>
                </select>
            </div>
        </div>

    </div>

    <div class="layui-form-item">

        <div class="layui-inline">
            <label class="layui-form-label">班级名称</label>
            <div class="layui-input-inline _input">
                <select name="classid"   lay-verify="required" lay-filter="class" lay-search="">
                    <option th:unless="${edit}" value="">直接选择或搜索选择</option>
                    <option th:each="item:${class}" th:checked="${edit?item.id==info.classid:false}" th:value="${item.id}" th:text="${item.classname}"></option>
                </select>
            </div>
        </div>
        <div class="layui-inline">
            <label class="layui-form-label">看班老师</label>
            <div class="layui-input-inline _input">
                <select name="teacherId" lay-verify="required"  lay-search="">
                    <option th:unless="${edit}" value="">直接选择或搜索选择</option>
                    <option th:each="item:${teachers}" th:checked="${edit?item.id==info.teacherId:false}" th:value="${item.id}" th:text="${item.teachername}"></option>
                </select>
            </div>
        </div>
    </div>
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">授课内容</label>
            <div class="layui-input-inline _textarea">
                <textarea type="text" name="mess"  th:value="${edit?info.mess:''}" lay-verify="required" class="layui-input"></textarea>
            </div>
        </div>


    </div>


    <div class="layui-form-item">
        <div class="layui-input-block" style="    margin-top: 50px;">
            <button class="layui-btn layui-btn-normal" style="margin-left: 30%" lay-submit lay-filter="saveBtn">确认保存
            </button>
            <button class="layui-btn layui-btn-normal" id="close">退出</button>
        </div>
    </div>
</form>
    <script th:src="@{/lay/lib/jquery-3.4.1/jquery-3.4.1.min.js}"></script>
<script src="/js/learn/tool/result.js"></script>
<script th:src="@{/lay/lib/layui-v2.5.5/layui.js}" charset="utf-8"></script>
<script th:src="@{/js/learn/evening_subject/edit.js}"></script>
<!--<script th:src="@{/js/management/checkClassjs/function.js}"></script>-->


</body>
</html>